package com.yingxin.yxerp.module.organization.vo.req;

import cn.hutool.core.collection.CollectionUtil;
import com.yingxin.yx.framework.commons.constant.CommonConst;
import com.yingxin.yx.framework.commons.dto.PageIn;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.ArrayList;
import java.util.List;

/**
 * 用户
 * @author fanchao
 * @since 2021-05-13
 */

@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "UserQueryVo对象", description = "用户")
public class UserQueryVo extends PageIn {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "id ")
    private String id;

    @ApiModelProperty(value = "用户名 ")
    private String username;

    @ApiModelProperty(value = "状态 0 禁用 1 启用 5 申请中")
    private String accountStatus;

    @ApiModelProperty(value = "姓名 ")
    private String staffName;

    @ApiModelProperty(value = "用户编号 ")
    private String staffNo;

    @ApiModelProperty(value = "是否锁定 ")
    private String lockFlag;

    @ApiModelProperty(value = "试用期 SY 在职 ZZ 待离职 DLZ 离职 LZ ")
    private String staffStatus;

    @ApiModelProperty(value = "试用期 SY 在职 ZZ 待离职 DLZ 离职 LZ ")
    private List<String> staffStatusList = new ArrayList<>();

    @ApiModelProperty(value = "部门id")
    private String deptId;

    @ApiModelProperty(value = "厂区id")
    private String companyId;

    @ApiModelProperty(value = "职位id")
    private String staffPositionId;

    @ApiModelProperty(value = "岗位id")
    private String workType;

    @ApiModelProperty(value = "电话")
    private String phone;

    @ApiModelProperty(value = "微信")
    private String wechatNickname;

    @ApiModelProperty(value = "qq号码")
    private String qq;

    @ApiModelProperty(value = "邮箱")
    private String email;

    @ApiModelProperty(value = "身份证号码")
    private String idCardNo;

    @ApiModelProperty(value = "性别")
    private String sex;

    @ApiModelProperty(value = "民族")
    private String nation;

    @ApiModelProperty(value = "政治面貌")
    private String politicalOutlook;

    @ApiModelProperty(value = "婚姻状态")
    private String maritalStatus;

    @ApiModelProperty(value = "籍贯-省")
    private String nativeProvince;

    @ApiModelProperty(value = "籍贯-市")
    private String nativeCity;

    @ApiModelProperty(value = "籍贯-区县")
    private String nativeDistrict;

    @ApiModelProperty(value = "居住地")
    private String residencePlace;

    @ApiModelProperty(value = "学历")
    private String education;

    @ApiModelProperty(value = "毕业学校")
    private String graduationSchool;

    @ApiModelProperty(value = "专业")
    private String major;

    @ApiModelProperty(value = "银行卡号码")
    private String bankCardNo;

    @ApiModelProperty(value = "开户行")
    private String bank;

    @ApiModelProperty(value = "备注")
    private String remarks;

    @ApiModelProperty(value = "综合搜索")
    private String keyword;

    @ApiModelProperty(value = "是否绑定微信")
    private String wechatOpenId;

    @ApiModelProperty(value = "是否允许登录APP")
    private String isAppLogon;

    @ApiModelProperty(value = "depart 含离职")
    private List<String> checkedList;

    public String getDepart() {
        return CollectionUtil.isEmpty(checkedList) ? null : (checkedList.contains("depart") ? CommonConst.TRUE : null);
    }

    /**
     * 员工状态汇总快捷查询
     * 	-- 全职员工数量， 实习员工数量， 其他员工数量
     * 	fullTimeNumber, internshipNumber, otherNumber
     * 	-- 员工状态信息
     * 	-- 正式员工数量， 试用员工数量， 待离职员工数量
     * 	formalNumber，probationNumber， waitResignNumber
     * 	-- 合同信息
     * 	-- 添加合同的员工, 未添加合同的员工， 超期未签约，30天内到期， 60天内到期, 90天内到期
     * 	addcontract, unAddcontract, contractNotSigned, within30Days, within60Days, within90Days
     */
    private String employeeSituation;

    /**
     * 员工类型
     */
    private String weComEmployeeType;

    /**
     * 员工状态
     */
    private String weComEmployeeStatus;

    /**
     * 户口类型
     */
    private String registeredResidenceType;

    /**
     * 社保状态
     */
    private String weComSocialSecurity;

}
